package models

// MaterialFolder 素材分组表
type MaterialFolder struct {
	ID         string `json:"id" gorm:"column:id;primaryKey;type:int;size:64;comment:主键"`
	MerchantID string `json:"merchant_id" gorm:"column:merchant_id;primaryKey;type:varchar(30);not null;default:'';comment:商户id"`
	Name       string `json:"name" gorm:"column:name;type:string;size:50;not null;default:'';comment:素材分组名称"`
	Type       int8   `json:"type" gorm:"column:type;type:tinyint(1);not null;default:1;comment:素材类型,1语音,2表情,3灯光"`
	Sort       int8   `json:"sort" gorm:"column:sort;type:tinyint(1);not null;default:0;comment:排序"`
	CreatedAt  int64  `json:"created_at" gorm:"column:created_at;autoCreateTime;type:int;size:64;not null;default:0;index:created_at;comment:创建时间"`
	DeletedAt  int64  `json:"deleted_at" gorm:"column:deleted_at;type:int;size:64;not null;default:0;comment:删除时间"`
}

// TableName 表名
func (MaterialFolder) TableName() string {
	return "material_folder_v2"
}

// 模式自动注册
func init() {
	Models = append(Models, &MaterialFolder{})
}
